<!-- 权限创建模态框 -->
<div>
    <div class="modal-header">
        <h5 class="modal-title">创建权限
            <button type="button" class="close" aria-hidden="true" ng-click="cancel()">&times;</button>
        </h5>
    </div>
    <div class="modal-body">
        <form class="form-horizontal" role="form">
            <div class="form-group ">
                <label class="col-sm-2 control-label">职位</label>
                <div class="col-sm-10">
                    <select class="form-control">
                        <option ng-repeat="r in roles" ng-click="setRole(r)">{{r.description}}</option>
                    </select>
                </div>
            </div>
            <div class="form-group ">
                <label class="col-sm-2 control-label">资源</label>
                <div class="col-sm-10">
                    <select class="form-control">
                        <option ng-repeat="r in resources" ng-click="setResource(r)">{{r.description}}</option>
                    </select>
                </div>
            </div>
            <div class="form-group ">
                <label for="balance" class="col-sm-2 control-label">权限</label>
                <div class="col-sm-10">
                    <input type="text" class="form-control" id="balance" ng-model="permission">
                </div>
            </div>
            <div class="form-group ">
                <label for="balance" class="col-sm-2 control-label">锁定</label>
                <div class="col-sm-10">
                    <div class="checkbox">
                        <label style="font-size: 12pt">
                            <input type="checkbox" ng-model="available">是否可用
                        </label>
                    </div>
                </div>
            </div>
        </form>
    </div>
    <div class="modal-footer">
        <button class="btn btn-primary" ng-click="create()">
            创建
        </button>
        <button class="btn btn-warning" ng-click="cancel()">
            取消
        </button>
    </div>
</div>